This invention relates to mass storage devices, and more particularly to a system, apparatus and method for asynchronous file and file system update on a universal serial bus (USB) mass storage device (MSD) while connected to a PC.
When a Universal Serial Bus (USB) Mass Storage Device (MSD) is connected to a host computer (PC), the device goes through a process called enumeration, the method used to inform the PC of the device's identification (Virtual LAN ID (VID), process identification number, PID)), function (i.e., human interface device (HID), mass storage device (MSD), etc.), capabilities (e.g. MSD size, name, etc.) and the like. An MSD device also informs the PC which interface to use when “talking” to the device. In the case of most MSD devices (such as those that work with Microsoft Windows operating systems), the Small Computer Systems Interface (SCSI) is used. The transport interface is defined as Bulk Only Transport (BOT), with transport of command, data, and status occurring solely via bulk endpoints and not via interrupt or control endpoints. These features are important because they are supported by the Microsoft Windows USB MSD driver.
The USB protocol encapsulates the SCSI commands sent to a USB device. The device decodes the SCSI commands and responds with a SCSI response encapsulated in a USB protocol. The USB protocol uses the Command Block Wrapper (CBW) for host to device communication and the Command Status Wrapper (CSW) for responses from the device to the host.
The traditional and usual mode of operation of a USB device is for the device to relinquish control of its file system to the host PC while connected via a USB port. This limitation does not allow the device to update the file system while connected to the PC, that is, there is no ability to asynchronously update the file system.